package vip.aning.gitsync.config;

import vip.aning.gitsync.constant.AppConst;
import vip.aning.gitsync.model.GitInfo;

public class ConfigManager {
    private static ConfigManager instance;
    private GitInfo gitInfo = new GitInfo()
            .setBranch(AppConst.branch)
            .setCommitMessage("auto commit")
            .setSelectLocalOrRemote(AppConst.local);

    // 私有构造函数，确保单例
    private ConfigManager() {
    }

    // 获取单例实例
    public static ConfigManager getInstance() {
        if (instance == null) {
            instance = new ConfigManager();
        }
        return instance;
    }

    // 获取配置项
    public GitInfo getGitInfo() {
        return this.gitInfo;
    }
}